package com.yuwenxin.core;


import org.apache.commons.codec.digest.DigestUtils;

public class PasswordEncodeUtil {
    public static String encodePassword(String psw){
        if (psw == null || "".equals(psw.trim())){
            return null;
        }else {
            return DigestUtils.sha1Hex(psw);
        }
    }
}
